package com.ueboot.weishop.service.order.impl;

import com.ueboot.weishop.entity.order.OrderReceiverEntity;
import com.ueboot.weishop.repository.order.OrderReceiverRepository;
import com.ueboot.weishop.service.order.OrderReceiverService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * Created by zl  on 2017-11-05 14:45:14.
 *
 * @author zl
 * @since 2.0 by autocode
 */
@Slf4j
@Service
public class OrderReceiverServiceImpl implements OrderReceiverService {

    @Autowired
    private OrderReceiverRepository orderReceiverRepository;

    @Override
    public OrderReceiverEntity save(OrderReceiverEntity s) {
        return orderReceiverRepository.save(s);
    }

    @Override
    public OrderReceiverEntity get(Long id) {
        return orderReceiverRepository.findOne(id);
    }

    @Override
    public OrderReceiverEntity findByOrderOrderNo(String orderNo) {
        return orderReceiverRepository.findByOrderOrderNo(orderNo);
    }
}
